package com.course.web.view;

import com.course.web.page.AdminUI;
import com.vaadin.navigator.View;
import com.vaadin.navigator.ViewChangeListener;
import com.vaadin.spring.annotation.SpringView;
import com.vaadin.spring.annotation.UIScope;
import com.vaadin.ui.CustomComponent;
import com.vaadin.ui.Label;
import com.vaadin.ui.VerticalLayout;

/**
 * Created by Justin on 2017/5/15.
 */
@SpringView(name = AdminHomeView.NAME, ui = AdminUI.class)
@UIScope
public class AdminHomeView extends CustomComponent implements View {
    public static final String NAME = "";

    public AdminHomeView() {
        init();
    }

    @Override
    public void enter(ViewChangeListener.ViewChangeEvent event) {

    }

    private void init() {
        VerticalLayout root = new VerticalLayout();
        root.addComponent(new Label("管理员你好"));
        setCompositionRoot(root);
        setSizeFull();
    }
}
